local skel = fk.CreateSkill {
  name = "#lb__yanyun-choose",
}

Fk:loadTranslationTable {
  ["#lb__yanyun-choose"] = "烟煴",
}

skel:addEffect("active", {
  target_filter = function (self, player, to_select, selected, selected_cards, card, extra_data)
    if #selected == 0 then
      return to_select.id == self.extra_data.id
    else
      local list = {}
      for _, to in ipairs(selected) do
        table.insertIfNeed(list, to:getNextAlive())
        table.insertIfNeed(list, to:getLastAlive())
      end
      return table.contains(list, to_select)
    end
  end,
  feasible = function (self, player, selected, selected_cards, card)
    return #selected > 1
  end,
  card_num = 0,
})

return skel
